home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Enigma Amiga Life 109
/
EnigmaAmiga109CD.iso
/
dalla rivista
/
amiga.free
/
sorgenti vari
/
wolfedit2 2.0.4 source.sit
/
WolfEdit2 2.0.4 Source
/
ULevelStatus.p
< prev
next >
Wrap
Text File
|
1996-09-29
|
1KB
|
52 lines
unit ULevelStatus;
interface
uses
UWolfDoc;
procedure ShowLevelStatus (map: TMap);
implementation
uses
UGoof, UDialog, UCreateLevel;
const
levelStatusDlogID = 140;
numObjectsItem = 2;
numGuardsItem = 3;
numTreasuresItem = 4;
numDoorsItem = 5;
numSecretDoorsItem = 6;
numRoomsItem = 7;
objectLimitItem = 8;
procedure ShowLevelStatus (map: TMap);
var
stats: ObjectCountRecord;
dlog: TDialog;
item: integer;
begin
CalculateStatistics(map.fCells, stats);
new(dlog);
dlog.IGetNewDialog(levelStatusDlogID);
with dlog do begin
SetTitle(concat(map.fMapList.GetLevelName(map.fLevelNumber), ' of ', map.fMapList.fFileName));
SetItemNum(numRoomsItem, stats.numRooms);
SetItemNum(numObjectsItem, stats.numSprites - stats.numGuards);
SetItemNum(numGuardsItem, stats.numGuards);
SetItemNum(numTreasuresItem, stats.numTreasures);
SetItemNum(numDoorsItem, stats.numDoors);
SetItemNum(numSecretDoorsItem, stats.numSecretDoors);
{$IFC FALSE}
if map.fMapList.fVersion.encounter >= 3 then
HideItem(objectLimitItem);
{$ENDC}
end;
dlog.Show;
item := dlog.DoModalDialog;
dlog.Free;
end;
end.